package org.millioncall.yueyoga.admin.service;

import java.util.List;
import java.util.Map;

import org.millioncall.openplatform.common.PaginatedList;
import org.millioncall.yueyoga.admin.model.Role;

public interface RoleService {
	List<Role> findRoleAll();

	public PaginatedList<Role> getRolesInPage(int start, int limit,
			Map<String, Object> map);

	public Role findRoleById(Integer id);

	public boolean updateRole(Map<String, Object> map);

	public boolean saveRole(Map<String, Object> map);
	
	public Role findRoleByName(String name);

	public void deleteRoleByIds(int[] id);

	public void deleteRoleGroupById(int[] id);

	public List<Role> findRolesByGroupId(String gpId);

	/**
	 * 根据角色重新指定权限
	 * @param roleId
	 * @param auIds
	 * @return
	 */
	public boolean grantRoleAuthorities(String roleId, String auIds);
}